<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
    这是我的博客
    <script>
         
        let num = prompt("请输入一个数字检查质数");
        top: 
        for(let i=2;i<num;i++){
            // console.log(i);
            for(let son = 2;son<i;son++){
                // 如果发现有被整除，就不合格，终止删除
                if(!(i%son)) continue top;
            }
            console.log(i);
        }
    </script>
</body>
</html>